export interface MenuItem {
  key: string;
  path: string;
  title: string;
  icon: string;
  hidden?: boolean;
  disabled?: boolean;
  requireAuth?: boolean;
  roles?: string[];
}

// 判断当前环境是否为开发环境
const isDev = import.meta.env.DEV;

// 扁平化的一级菜单配置 - 确保每项都有图标
export const menuItems: MenuItem[] = [
  {
    key: "create",
    path: "/",
    title: "添加应用",
    requireAuth: true,
    icon: "Circleplus",
  },
  {
    key: "home",
    path: "/home",
    title: "首页",
    requireAuth: true,
    icon: "Home",
  },
  {
    key: "space",
    path: "/space",
    title: "空间",
    requireAuth: true,
    icon: "Space",
  },
  {
    key: "market",
    path: "/market",
    title: "应用市场",
    requireAuth: true,
    icon: "Market",
  },
  {
    key: "example",
    path: "/example",
    title: "示例",
    requireAuth: true,
    icon: "Example",
    hidden: !isDev, // 只在开发环境显示，生产环境隐藏
  },
];

export default menuItems;
